package com.example.serviceImpl;

import com.example.bean.Statement;
import com.example.mapper.StatementMapper;
import com.example.service.StatementService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StatementServiceImpl implements StatementService {

    @Autowired
    private StatementMapper statementMapper;

    /**
     * 查询办卡盈利的金额
     */
    @Override
    public List<Statement> selectStatement() {
        return statementMapper.selectProfit();
    }


    public int insert(Statement statement){
        return statementMapper.insert(statement);
    }

    /**
     * 查询罚款所受金额
     */
    @Override
    public List<Statement> selectFine() {
        return statementMapper.selectFine();
    }

    /**
     * 显示所有金额之和
     */
    @Override
    public Statement selectAll() {
        return null;
    }
}
